﻿@model FFLTask.SRV.ViewModel.Task.EditModel
@using FFLTask.GLB.Global.Enum
@using Global.Core.Helper
<table id="edit_column_@TaskProcess.Accept">
    <tr>
        <th class="first_column">
            验收：
        </th>
        <td>
            <label>@Html.RadioButtonFor(m => m.Accept.AcceptOrNot, false, new { onclick = "hideQuality()" })不合格</label>
            <label>@Html.RadioButtonFor(m => m.Accept.AcceptOrNot, true, new { onclick = "showQuality()" })合格</label>
            <span id="quality">
                质量：@Html.DropDownListFor(m => m.Accept.Quality, Model.Accept.AllQualities.GetSelectListItems<TaskQuality>())
            </span>
        </td>
    </tr>
</table>
<script type="text/javascript">
    $(document).ready(function () {
        if ($("[name='@Html.NameFor(m=>m.Accept.AcceptOrNot)']:checked").val() == "False") {
            hideQuality();
        } else {
            showQuality();
        }
    });
    function hideQuality() {
        $("#quality").hide();
    }
    function showQuality() {
        $("#quality").show();
    }
</script>
